package cn.wzut.edut.dao;

import cn.wzut.edut.dao.inf.User;
import cn.wzut.edut.dao.inf.Menu;
import cn.wzut.edut.dao.mapper.SysUserMapper;
import cn.wzut.edut.dao.pojo.table.SysUser;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public class Test1 {
    @Autowired
    private SysUserMapper sysUserMapper;
    public long ttt(){
        return sysUserMapper.selectCount(null);
    }
    public List ttt1(){
        QueryWrapper<SysUser> queryWrapper = new QueryWrapper<>();
        queryWrapper.in("id","0");
        User login = new User();
        Menu menu = new Menu();
        menu.selectSysMenus(login.selectSysUserOnlyRole("1"));
        return sysUserMapper.selectList(queryWrapper);
    }
}
